import request from '../../utils/request'
const state={
	indexData:{}
}
const mutations={
	updateIndexData(state,indexData){
		state.indexData=indexData;
	}
}
const actions={
	// 获取接口
	async getIndexDataActions({commit}){
		const res =await request('/getIndexData');
		console.log(res,'indexData')
		// 触发mutations
		commit('updateIndexData',res.indexData)
	}
	
}
const getters={}
export default {
	namespaced:true,
	state,
	mutations,
	getters,
	actions
}